import axios from '../utils/axios'

// 添加位置
export const addPositons = (data: ModelType) => {
  return axios.get<{ message: string; statusCode: number }>('addPositions', {
    params: data,
  })
}

// 根据当前经纬度获取周围指定范围的人
interface Params {
  latitude: number
  longitude: number
  radius: number
}
export const getNearbyPositions = (data: Params) => {
  return axios.get<ModelType[]>('getNearbyPositions', {
    params: data,
  })
}
